package com.productivity.model;

import com.productivity.model.common.DrawType;
import com.productivity.model.common.Size3D;
import com.productivity.model.common.Vertex3D;

public class Platform extends StaticGameObject {
	
	private static float[] verts = { 	 -0.5f,0.5f, -0.5f,
										 -0.5f,-0.5f,-0.5f, 
										  0.5f,0.5f,-0.5f,
										
										-0.5f,-0.5f,-0.5f,
										 0.5f,-0.5f, -0.5f,
										 0.5f,0.5f,-0.5f, //back
										 
										 0.5f,0.5f,0.5f,
										 -0.5f,0.5f,0.5f,
										 0.5f,-0.5f, 0.5f,
										
										 0.5f,-0.5f,0.5f, 
										 -0.5f,0.5f,0.5f,
										 -0.5f,-0.5f,0.5f, //front
										 
										 -0.5f,0.5f, 0.5f,
										 -0.5f, 0.5f, -0.5f, 
										 -0.5f,-0.5f, 0.5f,
										 
										 -0.5f, -0.5f,0.5f,
										 -0.5f,0.5f,-0.5f,
										 -0.5f, -0.5f, -0.5f, //left
										 
										 0.5f,0.5f, -0.5f,
										 0.5f, 0.5f, 0.5f, 
										 0.5f,-0.5f, -0.5f,
										 
										 0.5f, -0.5f, -0.5f,
										 0.5f,0.5f, 0.5f,
										 0.5f, -0.5f, 0.5f, //right
										 
										 -0.5f,0.5f, 0.5f,
										 0.5f, 0.5f, 0.5f, 
										 -0.5f,0.5f, -0.5f,
										 
										 -0.5f, 0.5f, -0.5f,
										 0.5f,0.5f, 0.5f,
										 0.5f, 0.5f, -0.5f, //top
										 
										 -0.5f,-0.5f, -0.5f,
										 0.5f, -0.5f, -0.5f, 
										 -0.5f,-0.5f, 0.5f,
										 
										 -0.5f, -0.5f, 0.5f,
										 0.5f,-0.5f, -0.5f,
										 0.5f, -0.5f, 0.5f //bottom
	
	};
	private static float[] norms = { 	 	0,0,-1,
											0,0,-1,
											0,0,-1,
											0,0,-1,
											0,0,-1,
											0,0,-1,//back
		 
											0,0,1,
											0,0,1,
											0,0,1,
											0,0,1,
											0,0,1,
											0,0,1,//front
											
											-1,0,0,
											-1,0,0,
											-1,0,0,
											-1,0,0,
											-1,0,0,
											-1,0,0, //left
											 
											1,0,0,
											1,0,0,
											1,0,0, 
											1,0,0,
											1,0,0,
											1,0,0, //right
											 
										 	0,1,0,
											0,1,0,
											0,1,0,
											0,1,0,
											0,1,0,
											0,1,0, //top
											 
											0,-1,0,
											0,-1,0,
											0,-1,0,
											0,-1,0,
											0,-1,0,
											0,-1,0 //bottom
											 };
	
	
	public Platform(Vertex3D loc, Size3D size) {
		super();
		this.location = loc;
		this.size = size;
		this.vertices = Vertex3D.floatToVertex3DArray(verts);
		this.normals = Vertex3D.floatToVertex3DArray(norms);
	}
	public DrawType getDrawType() {
		return DrawType.TRIANGLES;
	}
	public void update(Map map) {}
	@Override
	public Size3D getModelSize() {
		return new Size3D(1,1,1);
	}

}
